package com.itheima.demo01;

import java.util.Scanner;

public class Test {

    //内存分析工具的使用步骤
    //1.利用 scanner 键盘输入类，卡住然后程序一直运行，
    //2.在控制台输入jps
    //3.再输入jhsdb hsdb
    //4.

    public static void main(String[] args) {
        //创建对象
        Frog frog = new Frog("小哇",1);
        System.out.println(frog.getName() +", " + frog.getAge());
        frog.swim();
        frog.eat();

        Rabbit rabbit = new Rabbit("小快",1);
        System.out.println(rabbit.getName() + ", " + rabbit.getAge());
        rabbit.eat();
        Scanner scanner = new Scanner(System.in);
        scanner.nextInt();

    }
}
